package cc.yugu.yhdw.webserver.web.controller.security.basic;

import cc.yugu.yhdw.common.annotation.ViewModel;
import cc.yugu.yhdw.common.domain.basic.PlatformInOutMoney;
import cc.yugu.yhdw.common.entity.json.PageResult;
import cc.yugu.yhdw.webserver.service.basic.PlatformInOutMoneyService;
import cc.yugu.yhdw.webserver.web.controller.security.SecurityController;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * 新添加类：总部流水
 *
 * @Date:Created in 2018/9/3 16:28
 * @Author:
 * @Modified By: zjn 2018/9/3 16:28
 */
@Controller
@RequestMapping(value = "/security/basic/platform_in_out_money")
public class PlatformInOutMoneyController extends SecurityController {

    @Autowired
    PlatformInOutMoneyService platformInOutMoneyService;

//    @RequestMapping(value = "index.htm")
//    public void index() {
//    }

//    @RequestMapping("page.htm")
//    @ViewModel(ViewModel.JSON)
//    @ResponseBody
//    public PageResult page(AgencyInOutMoney search) {
//        return PageResult.successResult(agencyInOutMoneyService.findPage(search));
//    }
    /**
     * 新增：首页账户余额信息分页查看
     *
     * @Param: [search]
     * @Return: cc.yugu.yhdw.common.entity.json.PageResult
     * @Author By: zjn 2018/8/31  16:59
     */
    @RequestMapping("pageMoney.htm")
    @ViewModel(ViewModel.JSON)
    @ResponseBody
    public PageResult pageMoney(PlatformInOutMoney search) {
        //SessionUser sessionUser = getSessionUser(httpSession);
        search.setPlatformId(1);
        return PageResult.successResult(platformInOutMoneyService.findPage(search));
    }
}
